$(function() {
    //初始化日期选择
    function search(days) {
        var dateUtils = new $().DateUtils();
        var startDate = dateUtils.getRecentDate(days);
        var endDate = dateUtils.getRecentDate(0);
        $('input[name^="filter_GES"]', "#custom_search").filter('input[name$="statDate"]').val(startDate);
        $('input[name^="filter_LES"]', "#custom_search").filter('input[name$="statDate"]').val(endDate);
        $('input[value="搜索"]', "#custom_search").click();
    }

    $(".selTab span").click(function(){
        $(".selTab span").removeClass("selected");
        $(this).addClass("selected");
        search($(this).attr("days"));
    });

    $(".selTab span").first().click();

});